package com.graduation.springbootinit.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.graduation.springbootinit.model.entity.ActivityPart.UserPoints;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface UserPointsMapper extends BaseMapper<UserPoints> {
    
    /**
     * 获取用户积分
     */
    @Select("SELECT points FROM community_activities_user_points WHERE user_id = #{userId}")
    Integer selectPointsByUserId(@Param("userId") Long userId);
} 